/////////////////////////////////////////////////////////////////////////////
// Name:        maintoolbar.h
// Purpose:     
// Author:      Brant Young
// Modified by: 
// Created:     Mon May 14 21:46:51 2007
// RCS-ID:      
// Copyright:   Copyright (c) daodict.com 2007
// Licence:     GPL 2.0
/////////////////////////////////////////////////////////////////////////////
#pragma once

#include <wx/toolbar.h>

class wxSearchCtrl;
class CHMHtmlWindow;
class wxHtmlCell;
class wxCheckBox;

/**
 * CHMFindToolBar class declaration
 */
class CHMFindToolBar: public wxToolBar
{

public:
    /// Constructors
    CHMFindToolBar(wxWindow* p_parent, CHMHtmlWindow* p_to_search, wxBitmap& close_bmp, wxBitmap& find_next_bmp);
    
    /// Destructor
    virtual ~CHMFindToolBar();
    
    /// Events
    void OnClose(wxCommandEvent& event);
    void OnFindNext(wxCommandEvent& event);
    //void OnAddons(wxCommandEvent& event);
    
    void find_forward();
    
    wxSearchCtrl* p_find_srchctrl;
    wxCheckBox* p_match_case_chkbox;


    /// Control identifiers
    enum {
        ID_FIND_TOOLBAR = 10059,
        ID_CLOSE,
        ID_NEXT,
        ID_PREVIOUS,
        ID_MATCH_CASE_CHKBOX,
        ID_FIND_SRCHCTRL
    };
    
protected:
    
    void InitEvents();
    
	CHMHtmlWindow* _p_html_wnd;
	wxHtmlCell* _p_cell;
	wxString _currWord;
};

